package com.info.zhiduoduo.admin.controller;

import com.info.zhiduoduo.admin.model.formbean.evaluate.QueryEvaluateByConditionFormBean;
import com.info.zhiduoduo.admin.model.formbean.evaluate.UpdateEvaluateDateFormBean;
import com.info.zhiduoduo.admin.model.formbean.evaluate.UpdateEvaluateFormBean;
import com.info.zhiduoduo.admin.service.EvaluateService;
import com.info.zhiduoduo.common.constants.SmartResult;
import com.info.zhiduoduo.common.formbean.BaseSimpleFormBean;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author wang
 */
@Api(tags = "管理端-评价列表")
@RestController
@RequestMapping("/evaluate")
public class EvaluateController {

	@Resource
	EvaluateService evaluateService;

	@ApiOperation("管理端查询评价列表")
	@PostMapping("/queryEvaluate")
	public SmartResult queryEvaluate(@RequestBody BaseSimpleFormBean<QueryEvaluateByConditionFormBean> formBean) {
		return evaluateService.queryEvaluate(formBean);
	}
	@ApiOperation("更改跟进情况说明")
	@PostMapping("/updateEvaluate")
	public SmartResult updateEvaluate(@RequestBody BaseSimpleFormBean<UpdateEvaluateFormBean> formBean) {
		return evaluateService.updateEvaluate(formBean);
	}

	@ApiOperation("修改跟进日期")
	@PostMapping("/updateEvaluateDate")
	public SmartResult updateEvaluateDate(@RequestBody BaseSimpleFormBean<UpdateEvaluateDateFormBean> formBean) {
		return evaluateService.updateEvaluateDate(formBean);
	}



}
